Skip to content

web: embed-followups - #871

Merged
foxnne merged 5 commits into
mainfrom
web/embed-followups
Oct 28, 2026
Merged

foxnne merged 5 commits into
mainfrom
web/embed-followups

Conversation

@fizzy-linux

@fizzy-linux fizzy-linux Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Part of fizzyedit/work#361

Credit: this follows Michael Belousov's #835 (embeddable Fizzy, several copies on one page) and his issue #829; the fixes here close the gaps found in it. (Added by the PM for work#361's Done.)
Rework: work#547

Goal

Part of fizzyedit/work#361. Support multiple embedded Fizzy copies with shared compilation and isolated keyboard/fullscreen handling. This round addresses the newest PR #871 ruling on linux/codex F1.

What changed and why

The existing scripts/test-web-text-input.sh now runs the embed test after the hidden-input test under Node, and offers --embed-only for its build-independent fixture. CI invokes that script from its existing web compilation step; the separate embed-test step is removed. All other PR behavior stays as supplied.

How it was verified

The embed-only runner passes without built web assets; after building web, the default runner reports both text-input: ok and embed.test: ok. Before this change the existing runner never executed the embed check. The two-copies regression test covers shared compilation, key isolation and per-copy fullscreen. Prior negative-test evidence against main is recorded in the supplied review thread; it was not repeated this round. Format, lint, native build, unit, integration, web build, check-web and SDK-version gates pass; counts and cached-result qualifications are in the harness gate report.

Not done / follow-ups

No browser interaction was changed or checked this round. Optional earlier findings remain follow-ups per the ruling. Publishing and the numbered FIXES comment are left to the harness; maintainer approval remains outstanding.

Changes (64 files, +355/-1647)
 .github/workflows/ci.yml                           |  46 +++---
 .github/workflows/web.yml                          |   3 +-
 AGENTS.md                                          |   1 -
 CONTRIBUTING.md                                    |   5 +-
 app/control/Server.zig                             |  33 +---
 app/layout/Region.zig                              |   8 +-
 backend/src/SDLBackend.zig                         |  28 +---
 backend/src/platform/win32_titlebar.zig            |  15 --
 backend/src/platform/window_layout.zig             |  22 ---
 build.zig.zon                                      |   5 -
 build/app.zig                                      |  53 ------
 build/plugins.zig                                  |  10 --
 build/sdk.zig                                      |   3 -
 build/web.zig                                      |   5 -
 docs/AGENT_WORK.md                                 |   8 +-
 docs/PITFALLS.md                                   |  20 ++-
 docs/PLUGINS.md                                    |   1 -
 plugins/chat/build.zig                             |  13 --
 plugins/chat/build.zig.zon                         |  19 ---
 plugins/chat/plugin.zig                            |  87 ----------
 plugins/chat/plugin.zig.zon                        |   8 -
 plugins/chat/src/DemoProvider.zig                  |  68 --------
 plugins/chat/src/View.zig                          | 181 --------------------
 plugins/chat/src/composer.zig                      | 121 --------------
 plugins/chat/static/integration.zig                |  63 -------
 plugins/markdown/plugin.zig                        |  23 +--
 plugins/markdown/src/markdown.zig                  |  43 ++---
 plugins/markdown/src/md/ast.zig                    |  18 +-
 plugins/markdown/src/md/block_heights.zig          |  26 +--
 plugins/markdown/src/md/html_images.zig            |  10 +-
 plugins/markdown/src/md/net_image.zig              |   3 +-
 plugins/markdown/src/md/render_ast.zig             | 129 ++++-----------
 plugins/markdown/src/md/supermd.zig                |  11 +-
 plugins/markdown/src/md/wikilink_scan.zig          |   4 +-
 plugins/workbench/src/Workbench.zig                |  30 +---
 scripts/check-examples.sh                          |   5 -
 scripts/test-web-text-input.sh                     |   9 +-
 sdk/AGENTS.md                                      |   4 -
 sdk/plugin_sdk.zig                                 |  10 --
 sdk/src/dylib.zig                                  |  34 ----
 sdk/src/sdk.zig                                    |   1 -
 sdk/src/services/chat.zig                          |  71 --------
 sdk/src/version.zig                                |   2 +-
 src/backend/backend_native.zig                     |   5 -
 src/backend/backend_web.zig                        |  10 --
 src/editor/Keybinds.zig                            |   6 +-
 src/editor/Workspaces.zig                          |  17 +-
 tests/demos.zig                                    |  87 ----------
 tests/fixtures/tape-plugin/build.zig               |  22 ---
 tests/fixtures/tape-plugin/build.zig.zon           |  18 --
 tests/fixtures/tape-plugin/play.zig                |  74 ---------
 tests/fixtures/tape-plugin/plugin.zig              |  22 ---
 tests/fixtures/tape-plugin/plugin.zig.zon          |   8 -
 tests/integration.zig                              | 182 ---------------------
 web/AGENTS.md                                      |  10 +-
 web/fizzy-worker.js                                |   7 +-
 web/fizzy.js                                       |  94 ++++++++---
 web/icon-192.png                                   | Bin 1331 -> 0 bytes
 web/icon-512.png                                   | Bin 2529 -> 0 bytes
 web/index.html                                     |  10 +-
 web/manifest.webmanifest                           |  14 --
 ...oard-s-correction-replaces-the-typed-word.patch |  14 +-
 web/tests/embed.test.mjs                           | 136 +++++++++++++++
 web/tests/text-input.test.js                       |   7 -
 64 files changed, 355 insertions(+), 1647 deletions(-)
Gates: 6 of 6 passed

scripts/check-fmt.sh (exit 0)

check-fmt: listing tracked files
check-fmt: checking 546 files

scripts/zb build --summary all (exit 0)

... (earlier output omitted)
|     +- compile lib tree-sitter debug native (reused)
|     +- compile lib freetype debug native (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- options (reused)
|     +- options (reused)
|     +- translate-c dvui-c cached
|     |  +- compile exe translate-c debug native (+21 more reused dependencies)
|     +- options cached
|     +- options cached
+- install text cached
|  +- compile lib text debug native cached 12ms MaxRSS:40M
|     +- WriteFile plugin_root.zig cached
|     +- WriteFile freetype (reused)
|     +- compile lib freetype debug native (reused)
|     +- WriteFile . (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- compile lib freetype debug native (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- options (reused)
|     +- translate-c dvui-c (+1 more reused dependencies)
|     +- options (reused)
|     +- options (reused)
+- install markdown cached
|  +- compile lib markdown debug native cached 12ms MaxRSS:40M
|     +- WriteFile plugin_root.zig cached
|     +- WriteFile freetype (reused)
|     +- compile lib freetype debug native (reused)
|     +- WriteFile . (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- compile lib freetype debug native (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- options (reused)
|     +- translate-c dvui-c (+1 more reused dependencies)
|     +- options (reused)
|     +- options (reused)
|     +- translate-c (reused)
+- install image cached
   +- compile lib image debug native cached 13ms MaxRSS:40M
      +- WriteFile plugin_root.zig cached
      +- WriteFile freetype (reused)
      +- compile lib freetype debug native (reused)
      +- WriteFile . (reused)
      +- compile lib tree-sitter debug native (reused)
      +- compile lib freetype debug native (reused)
      +- compile lib tree-sitter debug native (reused)
      +- options (reused)
      +- translate-c dvui-c (+1 more reused dependencies)
      +- options (reused)
      +- options (reused)


scripts/zb build test --summary all (exit 0)

... (earlier output omitted)
      +- WriteFile freetype cached
      +- compile lib freetype debug native cached 11ms MaxRSS:39M
      +- WriteFile . cached
      +- compile lib tree-sitter debug native cached 10ms MaxRSS:35M
      +- compile lib freetype debug native (reused)
      +- compile lib tree-sitter debug native (reused)
      +- translate-c dvui-c cached
      |  +- compile exe translate-c debug native cached 5ms MaxRSS:40M
      |     +- options cached
      |     +- options cached
      |     +- options cached
      |     +- run exe generate-def (aarch64.zig) cached
      |     |  +- compile exe generate-def debug native cached 5ms MaxRSS:38M
      |     +- run exe generate-def (amdgcn.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (arm.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (bpf.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (common.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (hexagon.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (loongarch.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (mips.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (neon.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (nvptx.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (powerpc.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (riscv.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (s390x.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (ve.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (wasm.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (x86_64.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (x86.zig) cached
      |     |  +- compile exe generate-def debug native (reused)
      |     +- run exe generate-def (xcore.zig) cached
      |        +- compile exe generate-def debug native (reused)
      +- options cached
      +- options cached


scripts/zb build test-integration --summary all (exit 0)

... (earlier output omitted)
|     +- options (reused)
|     +- options (reused)
+- run test fizzy-glass-tests cached
|  +- compile test fizzy-glass-tests debug native cached 12ms MaxRSS:40M
|     +- WriteFile freetype (reused)
|     +- compile lib freetype debug native (reused)
|     +- WriteFile . (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- compile lib freetype debug native (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- translate-c dvui-c (+1 more reused dependencies)
|     +- options (reused)
|     +- options (reused)
+- run test fizzy-plugin-loader-tests cached
|  +- compile test fizzy-plugin-loader-tests debug native cached 12ms MaxRSS:40M
|     +- WriteFile freetype (reused)
|     +- compile lib freetype debug native (reused)
|     +- WriteFile . (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- compile lib freetype debug native (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- translate-c dvui-c (+1 more reused dependencies)
|     +- options (reused)
|     +- options (reused)
+- run test fizzy-text-plugin-tests cached
|  +- compile test fizzy-text-plugin-tests debug native cached 12ms MaxRSS:40M
|     +- options (reused)
|     +- WriteFile freetype (reused)
|     +- compile lib freetype debug native (reused)
|     +- WriteFile . (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- compile lib freetype debug native (reused)
|     +- compile lib tree-sitter debug native (reused)
|     +- translate-c dvui-c (+1 more reused dependencies)
|     +- options (reused)
|     +- options (reused)
+- run test fizzy-workbench-plugin-tests cached
   +- compile test fizzy-workbench-plugin-tests debug native cached 12ms MaxRSS:40M
      +- options (reused)
      +- options (reused)
      +- WriteFile freetype (reused)
      +- compile lib freetype debug native (reused)
      +- WriteFile . (reused)
      +- compile lib tree-sitter debug native (reused)
      +- compile lib freetype debug native (reused)
      +- compile lib tree-sitter debug native (reused)
      +- translate-c dvui-c (+1 more reused dependencies)
      +- options (reused)
      +- options (reused)


scripts/zb build check-web --summary all (exit 0)

... (earlier output omitted)
|  |     +- run exe generate-def (amdgcn.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (arm.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (bpf.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (common.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (hexagon.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (loongarch.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (mips.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (neon.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (nvptx.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (powerpc.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (riscv.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (s390x.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (ve.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (wasm.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (x86_64.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (x86.zig) cached
|  |     |  +- compile exe generate-def debug native (reused)
|  |     +- run exe generate-def (xcore.zig) cached
|  |        +- compile exe generate-def debug native (reused)
|  +- options cached
|  +- options cached
|  +- options cached
|  +- options cached
|  +- options cached
|  +- options cached
|  +- options cached
|  +- options cached
|  +- options cached
|  +- options cached
|  +- translate-c cached 3ms MaxRSS:35M
+- compile obj rehome-fixture-web debug wasm32-freestanding cached 6ms MaxRSS:35M
   +- translate-c dvui-c (+1 more reused dependencies)
   +- options (reused)
   +- options (reused)


scripts/zb build test-sdk-version --summary all (exit 0)

... (earlier output omitted)
   +- WriteFile . cached
   +- compile lib tree-sitter debug native cached 10ms MaxRSS:34M
   +- compile lib freetype debug native (reused)
   +- compile lib tree-sitter debug native (reused)
   +- options cached
   +- options cached
   +- translate-c dvui-c cached
   |  +- compile exe translate-c debug native cached 7ms MaxRSS:40M
   |     +- options cached
   |     +- options cached
   |     +- options cached
   |     +- run exe generate-def (aarch64.zig) cached
   |     |  +- compile exe generate-def debug native cached 6ms MaxRSS:35M
   |     +- run exe generate-def (amdgcn.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (arm.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (bpf.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (common.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (hexagon.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (loongarch.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (mips.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (neon.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (nvptx.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (powerpc.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (riscv.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (s390x.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (ve.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (wasm.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (x86_64.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (x86.zig) cached
   |     |  +- compile exe generate-def debug native (reused)
   |     +- run exe generate-def (xcore.zig) cached
   |        +- compile exe generate-def debug native (reused)
   +- options cached
   +- options cached


@fizzy-pm

fizzy-pm Bot commented Oct 26, 2026

Copy link
Copy Markdown

PM note: how this PR will be handled

What it is for: web: embed-followups
Issue #361: web: embedding follow-ups to #835 (keys, fullscreen, shared compile; two-copies test)
Done when (from the issue): one PR with the fixes and a test that mounts two copies; #829 closes when it lands; credit to Michael in the PR.

Rules that apply: touches CI or workflows; changes agent rules or guides.
Reviews needed: 2, from two different kinds.
Needs the maintainer's explicit yes before merge: yes

Things to watch (checked by rule):

  • the body names its work issue (Part of fizzyedit/work#N)
  • size within 800 lines outside tests and docs (92)
  • a gates section with what was run

What happens next:

  1. Reviewers from other teams or kinds comment, with findings numbered F1, F2, ...
  2. The author answers every finding in one FIXES @<commit> comment (fixed in a commit, or declined with a reason) and pushes.
  3. Reviewers re-review the new commit on their own.
  4. When every finding is answered and the re-reviews are clean, the PM marks it ready and the full CI runs (a few times at most: run the failing job locally before you push again). Only when CI passes does the PM look, and the PM gives the final okay after asking the maintainer.

A living status comment below is kept current. Nothing here is a merge decision.

@fizzy-pm

fizzy-pm Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

Where this PR stands

Stage: Waiting for the maintainer
Next: Maintainer should say yes or no when the PM asks

What the PM needs before approving (ticks as it is met; the full CI runs only at the end, after the reviews are clean):

  • The body names its basis (Part of fizzyedit/work#N or a plan step)
  • Within the size limit: 99 of 800 lines outside tests and docs
  • The body shows which gates the author ran
  • No open findings at this commit
  • Every earlier finding was answered in a FIXES comment (1 answered)
  • Clean reviews at this commit from 2 different kinds: macos/agy, macos/claude (has 2)
  • Marked ready, which starts the full CI (the PM does this the moment the items above are met)
  • The full CI passes at this commit (CI is green)
  • The maintainer's explicit yes (ci, rules)
  • The PM's final okay (pm-approval)

Rules that apply: touches CI or workflows; changes agent rules or guides.

Reviews at the current commit (095720e):

Reviewer Verdict Findings
macos/agy clean none
macos/claude clean 2
windows/codex inconclusive none

6 earlier reviews are for older commits and will be redone.

Latest fixes comment: https://github.com/fizzyedit/work/issues/395#issuecomment-6452386864 (1 finding answered)

Updated 2026-10-27 23:01 UTC by the PM. This comment is edited in place.

@fizzy-windows fizzy-windows Bot added reviewing:windows-codex a windows/codex review is running reviewing:windows-claude a windows/claude review is running and removed reviewing:windows-codex a windows/codex review is running labels Oct 27, 2026
@fizzy-macos fizzy-macos Bot added reviewing:macos-claude a macos/claude review is running and removed reviewing:macos-claude a macos/claude review is running labels Oct 27, 2026
@fizzy-windows fizzy-windows Bot removed the reviewing:windows-claude a windows/claude review is running label Oct 27, 2026
@fizzy-pm fizzy-pm Bot added the pm:fixes author fixes the must-fix items label Oct 27, 2026
fizzy-linux Bot and others added 3 commits October 27, 2026 11:28
Main keeps its web JS tests in web/tests/; the embed test sat in a second directory.
CI still runs it in its own step: it needs no built web.js, unlike scripts/test-web-text-input.sh.

Agent-Team: linux
Worker: claude

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Main's fizzy.js imports TextInput from web.js; the stand-in lacked it after the merge.

Agent-Team: linux
Worker: claude

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@fizzy-pm fizzy-pm Bot added pm:verify the same reviewer verifies the fixes and removed pm:fixes author fixes the must-fix items labels Oct 27, 2026
@fizzy-windows fizzy-windows Bot added reviewing:windows-claude a windows/claude review is running and removed reviewing:windows-claude a windows/claude review is running labels Oct 27, 2026
@fizzy-linux fizzy-linux Bot added the reviewing:linux-codex a linux/codex review is running label Oct 27, 2026
@fizzy-windows fizzy-windows Bot removed the reviewing:windows-claude a windows/claude review is running label Oct 27, 2026
@fizzy-macos fizzy-macos Bot added reviewing:macos-claude a macos/claude review is running and removed reviewing:macos-claude a macos/claude review is running labels Oct 27, 2026
@fizzy-linux fizzy-linux Bot removed the reviewing:linux-codex a linux/codex review is running label Oct 27, 2026
@fizzy-macos fizzy-macos Bot added reviewing:macos-agy a macos/agy review is running and removed reviewing:macos-agy a macos/agy review is running labels Oct 27, 2026
@fizzy-pm fizzy-pm Bot added pm:fixes author fixes the must-fix items and removed pm:verify the same reviewer verifies the fixes labels Oct 27, 2026
Agent-Team: linux

Worker: codex
@fizzy-macos fizzy-macos Bot added the reviewing:macos-agy a macos/agy review is running label Oct 27, 2026
@fizzy-windows fizzy-windows Bot added the reviewing:windows-codex a windows/codex review is running label Oct 27, 2026
@fizzy-macos fizzy-macos Bot added reviewing:macos-claude a macos/claude review is running and removed reviewing:macos-agy a macos/agy review is running labels Oct 27, 2026
@fizzy-windows fizzy-windows Bot added reviewing:windows-codex a windows/codex review is running and removed reviewing:windows-codex a windows/codex review is running labels Oct 27, 2026
@fizzy-macos fizzy-macos Bot removed the reviewing:macos-claude a macos/claude review is running label Oct 27, 2026
@fizzy-pm
fizzy-pm Bot marked this pull request as ready for review October 27, 2026 20:47
@fizzy-windows fizzy-windows Bot added reviewing:windows-codex a windows/codex review is running and removed reviewing:windows-codex a windows/codex review is running labels Oct 27, 2026
@fizzy-pm fizzy-pm Bot removed the pm:fixes author fixes the must-fix items label Oct 27, 2026
@foxnne
foxnne added this pull request to the merge queue Oct 28, 2026
Merged via the queue into main with commit a0ab311 Oct 28, 2026
36 checks passed
@foxnne
foxnne deleted the web/embed-followups branch October 28, 2026 01:38
This was referenced Oct 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant